﻿<%@ Page Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<dynamic>" %>
<%@ Import Namespace="yibo.Models"%>

<asp:Content ID="ArticleListTitle" ContentPlaceHolderID="TitleContent" runat="server">
    articles list
</asp:Content>
<asp:Content ID="ArticleListContent" ContentPlaceHolderID="MainContent" runat="server">
    <% 
        if (TempData["operation"] == "insertArticle") 
        {
    %>
    <script type="text/javascript">alert("发布文章成功！")</script>
    <%
        } 
    %>
    <div>
        <table style="width:100%;">
            <tr>
                <td class="style2" rowspan="3" style="width: 8px">
                    <img alt="" src="" style="height: 60px; width: 64px" /></td>
                <td class="style13" colspan="2">
                    <input id="Button1" type="button" value="关注了3个博客" style="width: 298px" /></td>
            </tr>
            <tr>
                <td class="style14" colspan="2">
                    <input id="Button2" type="button" value="收藏了6个博文" style="width: 298px" /></td>
            </tr>
            <tr>
                <td class="style15" colspan="2">
                    <strong>SAY:</strong></td>
            </tr>
            <tr>
                <td class="style2" style="width: 8px">
                    <input id="Button6" type="button" value="上传头像" /></td>
                <td class="style15" colspan="2">
                    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                    <input id="Button3" onclick="javascript:window.location.href='/MyArticles/EditArticle'" type="button" value="我文章" />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <input id="Button4" 
                        type="button" value="我商品" /></td>
            </tr>
            <tr>
                <td class="style10" style="width: 8px">
                </td>
                <td class="style11" colspan="2">
                    <strong>关联商品：<span class="style6"><select id="Select3" name="D3" 
                        style="height: 30px; width: 393px">
                        <option></option>
                    </select>
                    <input id="Button5" type="button" value="NEW" /></span></strong></td>
            </tr>
            <tr>
                <td class="style7" style="width: 8px; height: 27px;">
                </td>
                <td class="style8" colspan="2" style="height: 27px">
                    <strong>查看分类：<select id="Select2" name="D2" style="height: 33px; width: 393px">
                        <option></option>
                        <option>原创随感</option>
                        <option>手工艺品</option>
                    </select><span class="style6">
                    <input id="Button9" 
                        onclick="javascript:window.location.href='/MyArticles/NewclassArticle'" 
                        type="button" value="NEW" /> </span></strong></td>
            </tr>
            <%
                int i = 0;
                foreach(article articleList in ViewData["articleList"] as IEnumerable<article> )
                {
            %>
            <tr>
                <td class="style2" rowspan="4" style="width: 8px">
                    &nbsp;</td>
                <td class="style1" rowspan="4">
                    <%=articleList.title%><br />
                    <%=articleList.articleContent%></td>
                <td class="style16">
                    <input id="Button8"  
                        onclick="javascript:window.location.href='/MyArticles/EditArticle/<%=i %>'" 
                        type="button" value=" 编辑" style="width: 47px" /><br/>
                    <input id="Button10"  
                        onclick="javascript:window.location.href='/MyArticles/ShowArticle/<%=i %>'" 
                        style="width: 48px" type="button" value="查看"/></td>
            </tr>
            <tr>
                <td class="style16">
                    &nbsp;</td>
            </tr>
            <tr>
                <td class="style16">
                    &nbsp;</td>
            </tr>
            <tr>
                <td class="style16">
                    &nbsp;</td>
            </tr>
            <%  i++;
            } %>
        </table>
    
    </div>
    <p>
        &nbsp;</p>
    <p class="style6">
        <strong>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </strong>
    </p>
    <p>
        &nbsp;</p>
</asp:Content>

<asp:Content ID="Content1" runat="server" contentplaceholderid="CssContent">
    <style type="text/css">
        .style1
        {
            width: 553px;
        }
    </style>
</asp:Content>


